package com.frame.cfg;

import java.util.List;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.method.support.HandlerMethodArgumentResolver;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter;

/**
 * 集成WebMvcConfigurerAdapter添加Spring MVC配置。如果要覆盖Spring MVC配置，采用注解@EnableWebMvc
 * @author sxjun1904
 * If you want to take complete control of Spring MVC, you can add your own @Configuration annotated with @EnableWebMvc.
 * If you want to keep Spring Boot MVC features, and you just want to add additional MVC configuration (interceptors, 
 * formatters, view controllers etc.) you can add your own @Bean of type WebMvcConfigurerAdapter, but without @EnableWebMvc
 */
@Configuration
public class WebMvcConfiguration extends WebMvcConfigurerAdapter{
	
	@Override
	public void addArgumentResolvers(List<HandlerMethodArgumentResolver> argumentResolvers) {
		argumentResolvers.add(new MiniMethodArgumentsResolver());
	}
	
}
